package com.platform.module.domain;

import com.baomidou.mybatisplus.annotation.TableField;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.platform.common.annotation.Excels;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.platform.common.annotation.Excel;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import javax.validation.constraints.NotBlank;
import com.platform.common.core.domain.BaseEntity;

import java.util.Date;

/**
 * 阀门数据记录对象 valve_record
 * 
 * @author wangqi
 * @date 2020-07-24
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("valve_record")
public class ValveRecord extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** id */
    @TableId(type = IdType.AUTO)
    private Long id;

    /** 阀门id */
    @NotBlank(message = "阀门id不能为空")
    @Excel(name = "阀门id", type = Excel.Type.IMPORT)
    private String valveId;


    /** 阀温度上限 */
    @Excel(name = "阀温度上限")
    private String max;

    /** 阀温度下限 */
    @Excel(name = "阀温度下限")
    private String min;

    /** 阀温度值 */
    @Excel(name = "阀温度值")
    private String temp;

    /** 室内温度 */
    @Excel(name = "室内温度")
    private String indoor;

    /** 工作时间 */
    @Excel(name = "工作时间")
    private String workTime;

    /** 阀门开度 */
    @Excel(name = "阀门开度")
    private String aperture;

    @TableField(exist = false)
    private String createBy;

    @TableField(exist = false)
    private String updateBy;

    @TableField(exist = false)
    private Date updateTime;
    /** 室温采集器类型 */
    @Excels({
            @Excel(name = "阀门ID", targetAttr = "valveId", type = Excel.Type.EXPORT),
    })
    @TableField(exist = false)
    private BaseValveData valveData ;

    /** 厂商信息 */
    @Excels({
            @Excel(name = "厂商名称", targetAttr = "factoryName", type = Excel.Type.EXPORT),
            @Excel(name = "厂商代码", targetAttr = "factoryCode", type = Excel.Type.EXPORT)
    })
    @TableField(exist = false)
    private BaseFactory factory;



    @TableField(exist = false)
    private String ids;

}
